<?php

namespace app\common\model;

use app\common\model\Base;
use traits\model\SoftDelete;

class OrderGoods extends Base {

    use SoftDelete;

    protected $deleteTime = 'delete_time';

    public function lists_left_image($order_id) {



        $this->alias('a');

        $this->join(' __GOODS__ b', '  b.id = a.goods_id', 'LEFT');
        $this->join(' __ORDER__ c', '  c.id = a.order_id', 'LEFT');

        $this->where('a.order_id=' . $order_id);

        $this->field('a.*, b.image');

        $lists = $this->select();

        return array_out($lists);
    }

}
